
//10/13/18
//Called in sldu_boiler.do
//Created in District Map Data Tracker.xlsx
/// for AK and VT replace sldu with codes (codes correspond to elections_vtd.do data)

replace sldu="1" if strpos(slduname,"A")!=0 & fstate==2
replace sldu="2" if strpos(slduname,"B")!=0 & fstate==2
replace sldu="3" if strpos(slduname,"C")!=0 & fstate==2
replace sldu="4" if strpos(slduname,"D")!=0 & fstate==2
replace sldu="5" if strpos(slduname,"E")!=0 & fstate==2
replace sldu="6" if strpos(slduname,"F")!=0 & fstate==2
replace sldu="7" if strpos(slduname,"G")!=0 & fstate==2
replace sldu="8" if strpos(slduname,"H")!=0 & fstate==2
replace sldu="9" if strpos(slduname,"I")!=0 & fstate==2
replace sldu="10" if strpos(slduname,"J")!=0 & fstate==2
replace sldu="11" if strpos(slduname,"K")!=0 & fstate==2
replace sldu="12" if strpos(slduname,"L")!=0 & fstate==2
replace sldu="13" if strpos(slduname,"M")!=0 & fstate==2
replace sldu="14" if strpos(slduname,"N")!=0 & fstate==2
replace sldu="15" if strpos(slduname,"O")!=0 & fstate==2
replace sldu="16" if strpos(slduname,"P")!=0 & fstate==2
replace sldu="17" if strpos(slduname,"Q")!=0 & fstate==2
replace sldu="18" if strpos(slduname,"R")!=0 & fstate==2
replace sldu="19" if strpos(slduname,"S")!=0 & fstate==2
replace sldu="20" if strpos(slduname,"T")!=0 & fstate==2

replace sldu="1" if strpos(slduname,"ADD")!=0 & fstate==50
replace sldu="2" if strpos(slduname,"BEN")!=0 & fstate==50
replace sldu="3" if strpos(slduname,"CAL")!=0 & fstate==50
replace sldu="4" if strpos(slduname,"CGI")!=0 & fstate==50
replace sldu="5" if strpos(slduname,"CHI")!=0 & fstate==50
replace sldu="6" if strpos(slduname,"E-O")!=0 & fstate==50
replace sldu="7" if strpos(slduname,"FRA")!=0 & fstate==50
replace sldu="8" if strpos(slduname,"LAM")!=0 & fstate==50
replace sldu="9" if strpos(slduname,"ORA")!=0 & fstate==50
replace sldu="10" if strpos(slduname,"RUT")!=0 & fstate==50
replace sldu="11" if strpos(slduname,"WAS")!=0 & fstate==50
replace sldu="12" if strpos(slduname,"WDM")!=0 & fstate==50
replace sldu="13" if strpos(slduname,"WSR")!=0 & fstate==50

replace sldu="1" if strpos(slduname,"Addison")!=0 & fstate==50
replace sldu="2" if strpos(slduname,"Bennington")!=0 & fstate==50
replace sldu="3" if strpos(slduname,"Caledonia")!=0 & fstate==50
replace sldu="4" if strpos(slduname,"Grand Isle")!=0 & fstate==50
replace sldu="5" if strpos(slduname,"Chittenden")!=0 & fstate==50
replace sldu="6" if strpos(slduname,"Essex-Orleans")!=0 & fstate==50
replace sldu="7" if strpos(slduname,"Franklin")!=0 & fstate==50
replace sldu="8" if strpos(slduname,"Lamoille")!=0 & fstate==50
replace sldu="9" if strpos(slduname,"Orange")!=0 & fstate==50
replace sldu="10" if strpos(slduname,"Rutland")!=0 & fstate==50
replace sldu="11" if strpos(slduname,"Washington")!=0 & fstate==50
replace sldu="12" if strpos(slduname,"Windham")!=0 & fstate==50
replace sldu="13" if strpos(slduname,"Windsor")!=0 & fstate==50


replace sldu="1" if slduname=="S03" & fstate==33
replace sldu="2" if slduname=="S24" & fstate==33
replace sldu="3" if slduname=="S19" & fstate==33
replace sldu="4" if slduname=="S11" & fstate==33
replace sldu="5" if slduname=="S20" & fstate==33
replace sldu="6" if slduname=="S03" & fstate==33
replace sldu="7" if slduname=="S02" & fstate==33
replace sldu="8" if slduname=="S22" & fstate==33
replace sldu="9" if slduname=="S14" & fstate==33
replace sldu="10" if slduname=="S04" & fstate==33
replace sldu="11" if slduname=="S18" & fstate==33
replace sldu="12" if slduname=="S15" & fstate==33
replace sldu="13" if slduname=="S21" & fstate==33
replace sldu="14" if slduname=="S09" & fstate==33
replace sldu="15" if slduname=="S05" & fstate==33
replace sldu="16" if slduname=="S08" & fstate==33
replace sldu="17" if slduname=="S01" & fstate==33
replace sldu="18" if slduname=="S17" & fstate==33
replace sldu="19" if slduname=="S14" & fstate==33
replace sldu="20" if slduname=="S08" & fstate==33
replace sldu="21" if slduname=="S11" & fstate==33
replace sldu="22" if slduname=="S22" & fstate==33
replace sldu="23" if slduname=="S13" & fstate==33
replace sldu="24" if slduname=="S07" & fstate==33
replace sldu="25" if slduname=="S04" & fstate==33
replace sldu="26" if slduname=="S18" & fstate==33
replace sldu="27" if slduname=="S16" & fstate==33
replace sldu="28" if slduname=="S12" & fstate==33
replace sldu="29" if slduname=="S23" & fstate==33
replace sldu="30" if slduname=="S04" & fstate==33
replace sldu="31" if slduname=="S16" & fstate==33
replace sldu="32" if slduname=="S06" & fstate==33
replace sldu="33" if slduname=="S17" & fstate==33
replace sldu="34" if slduname=="S02" & fstate==33
replace sldu="35" if slduname=="S16" & fstate==33
replace sldu="36" if slduname=="S06" & fstate==33
replace sldu="37" if slduname=="S05" & fstate==33
replace sldu="38" if slduname=="S03" & fstate==33
replace sldu="39" if slduname=="S01" & fstate==33
replace sldu="40" if slduname=="S07" & fstate==33
replace sldu="41" if slduname=="S10" & fstate==33
replace sldu="42" if slduname=="S05" & fstate==33




/// sldu then matched to codes generated in slducodes.do
replace sldu="1" if sldu=="Addison 1" & state_abbrev=="VT" & year==2017
replace sldu="2" if sldu=="Addison 2" & state_abbrev=="VT" & year==2017
replace sldu="3" if sldu=="Addison 3" & state_abbrev=="VT" & year==2017
replace sldu="4" if sldu=="Addison 4" & state_abbrev=="VT" & year==2017
replace sldu="5" if sldu=="Addison 5" & state_abbrev=="VT" & year==2017
replace sldu="6" if sldu=="Addison-Rutland" & state_abbrev=="VT" & year==2017
replace sldu="7" if sldu=="Bennington 1" & state_abbrev=="VT" & year==2017
replace sldu="8" if sldu=="Bennington 3" & state_abbrev=="VT" & year==2017
replace sldu="9" if sldu=="Bennington 4" & state_abbrev=="VT" & year==2017
replace sldu="10" if sldu=="Bennington-Rutland" & state_abbrev=="VT" & year==2017
replace sldu="11" if sldu=="Bennington 2-1" & state_abbrev=="VT" & year==2017
replace sldu="12" if sldu=="Bennington 2-2" & state_abbrev=="VT" & year==2017
replace sldu="13" if sldu=="Chittenden 1" & state_abbrev=="VT" & year==2017
replace sldu="14" if sldu=="Chittenden 2" & state_abbrev=="VT" & year==2017
replace sldu="15" if sldu=="Chittenden 3" & state_abbrev=="VT" & year==2017
replace sldu="16" if sldu=="Chittenden 10" & state_abbrev=="VT" & year==2017
replace sldu="17" if sldu=="Chittenden 4-1" & state_abbrev=="VT" & year==2017
replace sldu="18" if sldu=="Chittenden 4-2" & state_abbrev=="VT" & year==2017
replace sldu="19" if sldu=="Chittenden 5-1" & state_abbrev=="VT" & year==2017
replace sldu="20" if sldu=="Chittenden 5-2" & state_abbrev=="VT" & year==2017
replace sldu="21" if sldu=="Chittenden 6-1" & state_abbrev=="VT" & year==2017
replace sldu="22" if sldu=="Chittenden 6-2" & state_abbrev=="VT" & year==2017
replace sldu="23" if sldu=="Chittenden 6-3" & state_abbrev=="VT" & year==2017
replace sldu="24" if sldu=="Chittenden 6-4" & state_abbrev=="VT" & year==2017
replace sldu="25" if sldu=="Chittenden 6-5" & state_abbrev=="VT" & year==2017
replace sldu="26" if sldu=="Chittenden 6-6" & state_abbrev=="VT" & year==2017
replace sldu="27" if sldu=="Chittenden 6-7" & state_abbrev=="VT" & year==2017
replace sldu="28" if sldu=="Chittenden 7-1" & state_abbrev=="VT" & year==2017
replace sldu="29" if sldu=="Chittenden 7-2" & state_abbrev=="VT" & year==2017
replace sldu="30" if sldu=="Chittenden 7-3" & state_abbrev=="VT" & year==2017
replace sldu="31" if sldu=="Chittenden 7-4" & state_abbrev=="VT" & year==2017
replace sldu="32" if sldu=="Chittenden 8-1" & state_abbrev=="VT" & year==2017
replace sldu="33" if sldu=="Chittenden 8-2" & state_abbrev=="VT" & year==2017
replace sldu="34" if sldu=="Chittenden 8-3" & state_abbrev=="VT" & year==2017
replace sldu="35" if sldu=="Chittenden 9-1" & state_abbrev=="VT" & year==2017
replace sldu="36" if sldu=="Chittenden 9-2" & state_abbrev=="VT" & year==2017
replace sldu="37" if sldu=="Caledonia 1" & state_abbrev=="VT" & year==2017
replace sldu="38" if sldu=="Caledonia 2" & state_abbrev=="VT" & year==2017
replace sldu="39" if sldu=="Caledonia 3" & state_abbrev=="VT" & year==2017
replace sldu="40" if sldu=="Caledonia 4" & state_abbrev=="VT" & year==2017
replace sldu="41" if sldu=="Caledonia-Washington" & state_abbrev=="VT" & year==2017
replace sldu="42" if sldu=="Essex-Caledonia" & state_abbrev=="VT" & year==2017
replace sldu="43" if sldu=="Essex-Caledonia-Orleans" & state_abbrev=="VT" & year==2017
replace sldu="44" if sldu=="Franklin 1" & state_abbrev=="VT" & year==2017
replace sldu="45" if sldu=="Franklin 2" & state_abbrev=="VT" & year==2017
replace sldu="46" if sldu=="Franklin 4" & state_abbrev=="VT" & year==2017
replace sldu="47" if sldu=="Franklin 5" & state_abbrev=="VT" & year==2017
replace sldu="48" if sldu=="Franklin 6" & state_abbrev=="VT" & year==2017
replace sldu="49" if sldu=="Franklin 7" & state_abbrev=="VT" & year==2017
replace sldu="50" if sldu=="Franklin 3-1" & state_abbrev=="VT" & year==2017
replace sldu="51" if sldu=="Franklin 3-2" & state_abbrev=="VT" & year==2017
replace sldu="52" if sldu=="Grandisle-Chittenden" & state_abbrev=="VT" & year==2017
replace sldu="52" if sldu=="Grandisle" & state_abbrev=="VT"
replace sldu="53" if sldu=="Lamoille 1" & state_abbrev=="VT" & year==2017
replace sldu="54" if sldu=="Lamoille 2" & state_abbrev=="VT" & year==2017
replace sldu="55" if sldu=="Lamoille 3" & state_abbrev=="VT" & year==2017
replace sldu="56" if sldu=="Lamoille-Washington" & state_abbrev=="VT" & year==2017
replace sldu="57" if sldu=="Orange 1" & state_abbrev=="VT" & year==2017
replace sldu="58" if sldu=="Orange 2" & state_abbrev=="VT" & year==2017
replace sldu="59" if sldu=="Orange-Caledonia" & state_abbrev=="VT" & year==2017
replace sldu="60" if sldu=="Orleans-Lamoille" & state_abbrev=="VT" & year==2017
replace sldu="61" if sldu=="Orleans-Caledonia" & state_abbrev=="VT" & year==2017
replace sldu="62" if sldu=="Orleans 1" & state_abbrev=="VT" & year==2017
replace sldu="63" if sldu=="Orleans 2" & state_abbrev=="VT" & year==2017
replace sldu="64" if sldu=="Orange-Washington-Addison" & state_abbrev=="VT" & year==2017
replace sldu="65" if sldu=="Rutland 1" & state_abbrev=="VT" & year==2017
replace sldu="66" if sldu=="Rutland 2" & state_abbrev=="VT" & year==2017
replace sldu="67" if sldu=="Rutland 3" & state_abbrev=="VT" & year==2017
replace sldu="68" if sldu=="Rutland 4" & state_abbrev=="VT" & year==2017
replace sldu="69" if sldu=="Rutland 6" & state_abbrev=="VT" & year==2017
replace sldu="70" if sldu=="Rutland-Bennington" & state_abbrev=="VT" & year==2017
replace sldu="71" if sldu=="Rutland-Windsor 1" & state_abbrev=="VT" & year==2017
replace sldu="72" if sldu=="Rutland 5-1" & state_abbrev=="VT" & year==2017
replace sldu="73" if sldu=="Rutland 5-2" & state_abbrev=="VT" & year==2017
replace sldu="74" if sldu=="Rutland 5-3" & state_abbrev=="VT" & year==2017
replace sldu="75" if sldu=="Rutland 5-4" & state_abbrev=="VT" & year==2017
replace sldu="76" if sldu=="Rutland-Windsor 2" & state_abbrev=="VT" & year==2017
replace sldu="77" if sldu=="Windham 1" & state_abbrev=="VT" & year==2017
replace sldu="78" if sldu=="Windham 3" & state_abbrev=="VT" & year==2017
replace sldu="79" if sldu=="Windham 4" & state_abbrev=="VT" & year==2017
replace sldu="80" if sldu=="Windham 5" & state_abbrev=="VT" & year==2017
replace sldu="81" if sldu=="Windham 6" & state_abbrev=="VT" & year==2017
replace sldu="82" if sldu=="Windham 2-1" & state_abbrev=="VT" & year==2017
replace sldu="83" if sldu=="Windham 2-2" & state_abbrev=="VT" & year==2017
replace sldu="84" if sldu=="Windham 2-3" & state_abbrev=="VT" & year==2017
replace sldu="85" if sldu=="Washington 1" & state_abbrev=="VT" & year==2017
replace sldu="86" if sldu=="Washington 2" & state_abbrev=="VT" & year==2017
replace sldu="87" if sldu=="Washington 3" & state_abbrev=="VT" & year==2017
replace sldu="88" if sldu=="Washington 4" & state_abbrev=="VT" & year==2017
replace sldu="89" if sldu=="Washington 5" & state_abbrev=="VT" & year==2017
replace sldu="90" if sldu=="Washington 6" & state_abbrev=="VT" & year==2017
replace sldu="91" if sldu=="Washington 7" & state_abbrev=="VT" & year==2017
replace sldu="92" if sldu=="Washington-Chittenden" & state_abbrev=="VT" & year==2017
replace sldu="93" if sldu=="Windham-Bennington-Windsor" & state_abbrev=="VT" & year==2017
replace sldu="94" if sldu=="Windham-Bennington" & state_abbrev=="VT" & year==2017
replace sldu="95" if sldu=="Windsor 1" & state_abbrev=="VT" & year==2017
replace sldu="96" if sldu=="Windsor 2" & state_abbrev=="VT" & year==2017
replace sldu="97" if sldu=="Windsor 5" & state_abbrev=="VT" & year==2017
replace sldu="98" if sldu=="Windsor-Rutland" & state_abbrev=="VT" & year==2017
replace sldu="99" if sldu=="Windsor 3-1" & state_abbrev=="VT" & year==2017
replace sldu="100" if sldu=="Windsor 3-2" & state_abbrev=="VT" & year==2017
replace sldu="101" if sldu=="Windsor 4-1" & state_abbrev=="VT" & year==2017
replace sldu="102" if sldu=="Windsor 4-2" & state_abbrev=="VT" & year==2017
replace sldu="103" if sldu=="Windsor-Orange 1" & state_abbrev=="VT" & year==2017
replace sldu="104" if sldu=="Windsor-Orange 2" & state_abbrev=="VT" & year==2017
replace sldu="1" if sldu=="Chittenden 3-10" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="2" if sldu=="Addison 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="3" if sldu=="Addison 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="4" if sldu=="Addison 3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="5" if sldu=="Addison 4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="6" if sldu=="Addison 5" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="7" if sldu=="Addison-Rutland 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="8" if sldu=="Bennington 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="9" if sldu=="Bennington 3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="10" if sldu=="Bennington 4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="11" if sldu=="Bennington 5" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="12" if sldu=="Bennington 2-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="13" if sldu=="Bennington 2-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="14" if sldu=="Bennington-Rutland 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="15" if sldu=="Chittenden 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="16" if sldu=="Chittenden 4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="17" if sldu=="Chittenden 8" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="18" if sldu=="Chittenden 9" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="19" if sldu=="Chittenden 1-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="20" if sldu=="Chittenden 1-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="21" if sldu=="Chittenden 3-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="22" if sldu=="Chittenden 3-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="23" if sldu=="Chittenden 3-3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="24" if sldu=="Chittenden 3-4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="25" if sldu=="Chittenden 3-5" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="26" if sldu=="Chittenden 3-6" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="27" if sldu=="Chittenden 3-7" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="28" if sldu=="Chittenden 3-8" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="29" if sldu=="Chittenden 3-9" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="30" if sldu=="Chittenden 5-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="31" if sldu=="Chittenden 5-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="32" if sldu=="Chittenden 6-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="33" if sldu=="Chittenden 6-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="34" if sldu=="Chittenden 6-3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="35" if sldu=="Chittenden 7-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="36" if sldu=="Chittenden 7-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="37" if sldu=="Caledonia 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="38" if sldu=="Caledonia 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="39" if sldu=="Caledonia 3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="40" if sldu=="Caledonia 4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="41" if sldu=="Caledonia-Washington 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="42" if sldu=="Essex-Caledonia 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="43" if sldu=="Essex-Caledonia-Orleans 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="44" if sldu=="Franklin 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="45" if sldu=="Franklin 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="46" if sldu=="Franklin 3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="47" if sldu=="Franklin 4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="48" if sldu=="Franklin 5" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="49" if sldu=="Franklin 6" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="50" if sldu=="Grandisle-Chittenden 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="51" if sldu=="Lamoille 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="52" if sldu=="Lamoille 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="53" if sldu=="Lamoille 3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="54" if sldu=="Lamoille 4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="55" if sldu=="Lamoille-Washington 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="56" if sldu=="Orange-Addison 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="57" if sldu=="Orange 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="58" if sldu=="Orange 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="59" if sldu=="Orange-Caledonia 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="60" if sldu=="Orleans 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="61" if sldu=="Orleans 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="62" if sldu=="Orleans-Caledonia 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="63" if sldu=="Orleans-Franklin 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="64" if sldu=="Rutland 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="65" if sldu=="Rutland 3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="66" if sldu=="Rutland 4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="67" if sldu=="Rutland 6" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="68" if sldu=="Rutland 7" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="69" if sldu=="Rutland 8" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="70" if sldu=="Rutland 1-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="71" if sldu=="Rutland 1-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="72" if sldu=="Rutland 5-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="73" if sldu=="Rutland 5-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="74" if sldu=="Rutland 5-3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="75" if sldu=="Rutland 5-4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="76" if sldu=="Rutland-Windsor 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="77" if sldu=="Washington 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="78" if sldu=="Washington 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="79" if sldu=="Washington 4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="80" if sldu=="Washington 5" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="81" if sldu=="Washington 6" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="82" if sldu=="Washington 7" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="83" if sldu=="Washington 3-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="84" if sldu=="Washington 3-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="85" if sldu=="Washington 3-3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="86" if sldu=="Washington-Chittenden 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="87" if sldu=="Windham 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="88" if sldu=="Windham 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="89" if sldu=="Windham 4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="90" if sldu=="Windham 5" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="91" if sldu=="Windham 6" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="92" if sldu=="Windham 3-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="93" if sldu=="Windham 3-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="94" if sldu=="Windham 3-3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="95" if sldu=="Windham-Bennington 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="96" if sldu=="Windham-Bennington-Windsor 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="97" if sldu=="Windsor 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="98" if sldu=="Windsor 3" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="99" if sldu=="Windsor 4" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="100" if sldu=="Windsor 5" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="101" if sldu=="Windsor 1-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="102" if sldu=="Windsor 1-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="103" if sldu=="Windsor 6-1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="104" if sldu=="Windsor 6-2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="105" if sldu=="Windsor-Orange 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="106" if sldu=="Windsor-Orange 2" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="107" if sldu=="Windsor-Rutland 1" & state_abbrev=="VT" & (year==2012 | year==2007)
replace sldu="108" if sldu=="Windsor-Rutland 2" & state_abbrev=="VT" & (year==2012 | year==2007)


replace sldu="22" if slduname=="Capital 1" & fstate==32
replace sldu="23" if slduname=="Central 1" & fstate==32
replace sldu="24" if slduname=="Clark 1" & fstate==32
replace sldu="25" if slduname=="Clark 10" & fstate==32
replace sldu="26" if slduname=="Clark 11" & fstate==32
replace sldu="27" if slduname=="Clark 12" & fstate==32
replace sldu="28" if slduname=="Clark 2" & fstate==32
replace sldu="29" if slduname=="Clark 3" & fstate==32
replace sldu="30" if slduname=="Clark 4" & fstate==32
replace sldu="31" if slduname=="Clark 5" & fstate==32
replace sldu="32" if slduname=="Clark 6" & fstate==32
replace sldu="33" if slduname=="Clark 7" & fstate==32
replace sldu="34" if slduname=="Clark 8" & fstate==32
replace sldu="35" if slduname=="Clark 9" & fstate==32
replace sldu="36" if slduname=="Northern 1" & fstate==32
replace sldu="37" if slduname=="Rural 1" & fstate==32
replace sldu="38" if slduname=="Washoe 1" & fstate==32
replace sldu="39" if slduname=="Washoe 2" & fstate==32
replace sldu="40" if slduname=="Washoe 3" & fstate==32
replace sldu="41" if slduname=="Washoe 4" & fstate==32

replace sldu="1" if slduname=="Second Essex & Middlesex" & fstate==25
replace sldu="2" if slduname=="First Suffolk & Middlesex" & fstate==25
replace sldu="3" if slduname=="Second Hampden & Hampshire" & fstate==25
replace sldu="4" if slduname=="Hampshire & Franklin" & fstate==25
replace sldu="5" if slduname=="First Essex & Middlesex" & fstate==25
replace sldu="6" if slduname=="First Essex" & fstate==25
replace sldu="7" if slduname=="Middlesex & Worcester" & fstate==25
replace sldu="8" if slduname=="First Hampden & Hampshire" & fstate==25
replace sldu="9" if slduname=="First Middlesex" & fstate==25
replace sldu="10" if slduname=="Second Essex" & fstate==25
replace sldu="11" if slduname=="Norfolk Bristol & Middlesex" & fstate==25
replace sldu="12" if slduname=="Bristol & Norfolk" & fstate==25
replace sldu="13" if slduname=="Second Bristol & Plymouth" & fstate==25
replace sldu="14" if slduname=="Second Middlesex & Norfolk" & fstate==25
replace sldu="15" if slduname=="Norfolk & Plymouth" & fstate==25
replace sldu="16" if slduname=="Cape & Islands" & fstate==25
replace sldu="17" if slduname=="First Suffolk" & fstate==25
replace sldu="18" if slduname=="Worcester Hampden Hampshire & Franklin" & fstate==25
replace sldu="19" if slduname=="Plymouth & Barnstable" & fstate==25
replace sldu="20" if slduname=="Plymouth & Norfolk" & fstate==25
replace sldu="21" if slduname=="Norfolk & Suffolk" & fstate==25
replace sldu="22" if slduname=="Second Plymouth & Bristol" & fstate==25
replace sldu="23" if slduname=="First Plymouth & Bristol" & fstate==25
replace sldu="24" if slduname=="Middlesex & Essex" & fstate==25
replace sldu="25" if slduname=="Norfolk Bristol & Plymouth" & fstate==25
replace sldu="26" if slduname=="Worcester & Norfolk" & fstate==25
replace sldu="27" if slduname=="Second Middlesex" & fstate==25
replace sldu="28" if slduname=="Worcester & Middlesex" & fstate==25
replace sldu="29" if slduname=="First Worcester" & fstate==25
replace sldu="30" if slduname=="Berkshire Hampshire Franklin & Hampden" & fstate==25
replace sldu="31" if slduname=="First Bristol & Plymouth" & fstate==25
replace sldu="32" if slduname=="First Middlesex & Norfolk" & fstate==25
replace sldu="33" if slduname=="Third Middlesex" & fstate==25
replace sldu="34" if slduname=="Middlesex Suffolk & Essex" & fstate==25
replace sldu="35" if slduname=="Second Worcester" & fstate==25
replace sldu="36" if slduname=="Suffolk & Norfolk" & fstate==25
replace sldu="37" if slduname=="Fourth Middlesex" & fstate==25
replace sldu="38" if slduname=="Third Essex & Middlesex" & fstate==25
replace sldu="39" if slduname=="Hampden" & fstate==25
replace sldu="40" if slduname=="Worcester Hampden Hampshire & Middlesex" & fstate==25
replace sldu="41" if slduname=="Fifth Middlesex" & fstate==25
replace sldu="42" if slduname=="Hampshire Franklin & Worcester" & fstate==25
replace sldu="43" if slduname=="Berkshire Hampshire & Franklin" & fstate==25
replace sldu="44" if slduname=="Second Suffolk & Middlesex" & fstate==25
replace sldu="45" if slduname=="Second Suffolk" & fstate==25
replace sldu="46" if slduname=="Middlesex & Suffolk" & fstate==25
replace sldu="47" if slduname=="Third Essex" & fstate==25
